<?php
/**
 * This is class IndexController
 *
 */
class IndexController extends Zend_Controller_Action {
	
	/**
	 * This is method init
	 *
	 * @return mixed This is the return value description
	 *
	 */
	public function init() {
		/* Initialize action controller here */
	}
	
	/**
	 * indexAction
	 *
	 * @return void
	 */
	public function indexAction() {
		$this->view->title = "Welcome to REST API web services";
		$this->view->headTitle($this->view->title);	
		
		try {
			// Get the user info from the storage (session)  
			$storage = Zend_Auth::getInstance()->getStorage();	// storage of Zend_Auth
			$user = $storage->read();
			$this->view->user = $user;
		} catch(Exception $e) {
			echo '<br />' . $e->getMessage();
		}		
	}
}